package com.company.gxcpc2018;

import java.util.Scanner;

public class Gxcpc1 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int t = sc.nextInt();
        while (t-- > 0) {
            int n = sc.nextInt();
            StringBuilder str = new StringBuilder();
            for (int i = 0; i < n; i++) {
                str.append("AC ");
            }
            System.out.println(str.toString().trim());
        }
    }
}
